#pragma once
#include "HashBucket.h"
namespace My_udset {

	template<class K>
	class unordered_set {
	public:
		struct KofT {
			const K& operator()(const K& key) {
				return key;
			}
		};
		typedef typename HashBucket::Hash<K, K, KofT>::con_iterator iterator;		
			iterator begin() const
			{
				return sh.begin();
			}

			iterator end() const
			{
				return sh.end();
			}

		pair<iterator,bool> insert(const K& key) 
		{
			pair<typename HashBucket::Hash<K, K, KofT>::iterator, bool> ret = sh.Insert(key);
			return pair<iterator, bool>(ret.first, ret.second);
		}
	private:
		HashBucket::Hash<K, K,KofT> sh;  
	};
}